package com.pug.zixun.service.msg;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import com.pug.zixun.mapper.KssMsgSystemMapper;
import com.pug.zixun.pojo.KssMsgSystem;
import com.pug.zixun.vo.KssSystemMsgVo;
import org.checkerframework.checker.units.qual.K;
import org.springframework.stereotype.Service;

/**
 * @author 谢迅
 * @version 1.0
 * @date 2022/10/9 15:18
 */
@Service
public class IKssMsgSystemServiceImpl extends ServiceImpl<KssMsgSystemMapper, KssMsgSystem> implements IKssMsgSystemService {

    @Override
    public IPage findMsgSystemPage(KssSystemMsgVo kssSystemMsgVo) {
        Page<KssMsgSystem> page=new Page<>(kssSystemMsgVo.getPageNo(),kssSystemMsgVo.getPageSize());
        return this.page(page);
    }

    @Override
    public boolean delById(Long id) {
        KssMsgSystem kssMsgSystem=new KssMsgSystem();
        kssMsgSystem.setStatus(1);
        kssMsgSystem.setId(id);
        return this.updateById(kssMsgSystem);
    }
}
